.algorithm-container {
  display: flex;
  justify-content: space-between;
  width: 100%;
}

.left-section {
  width: 20%;
  padding: 10px;
  box-sizing: border-box;
}

.middle-section {
  width: 70%;
  padding: 10px;
  box-sizing: border-box;
}

.right-section {
  width: 30%;
  padding: 10px;
  box-sizing: border-box;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
}

.algorithm-list {
  list-style-type: none;
  padding: 0;
  margin-right: 20px;
  padding-top: 10px;
  padding-bottom: 10px;
}

.algorithm {
  cursor: pointer;
  padding: 5px 10px;
  border: 1px solid #ccc;
  margin-bottom: 5px;
}

.algorithm:hover {
  background-color: #f0f0f0;
}

#Algorithms {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  height: 800px;
}

#p5js-container {
  display: flex;
  flex-direction: column;
  align-items: center;
}

#control-container {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
}

#control-container > div {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 20px;
  width: calc(100% / 3);
}

#control-container .element-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 10px;
  margin-right: 10px;
}

.element-container {
  background-color: #27272c;
}

#control-container span {
  font-size: 1.1rem;
}

.button-algo {
  position: relative;
  background: #444;
  color: #fff;
  text-decoration: none;
  text-transform: uppercase;
  border: none;
  letter-spacing: 0.1rem;
  font-size: 1vw;
  padding: 1vw 3vw;
  transition: 0.2s;
  margin: 10px;
  cursor: pointer;
}

@media screen and (max-width: 720px) {
  .button-algo {
    font-size: 1rem;
    padding: 0.5rem 1.5rem;
  }
}

.button-algo:hover {
  letter-spacing: 0.2rem;
  padding: 1.1rem 3.1rem;
  background: var(--clr);
  color: var(--clr);
  /* box-shadow: 0 0 35px var(--clr); */
  animation: box 3s infinite;
}

.button-algo::before {
  content: "";
  position: absolute;
  inset: 2px;
  background: #272822;
}

.button-algo span {
  position: relative;
  z-index: 1;
}
.button-algo i {
  position: absolute;
  inset: 0;
  display: block;
}

.button-algo i::before {
  content: "";
  position: absolute;
  width: 10px;
  height: 2px;
  left: 80%;
  top: -2px;
  border: 2px solid var(--clr);
  background: #272822;
  transition: 0.2s;
}

.button-algo:hover i::before {
  width: 15px;
  left: 20%;
  animation: move 3s infinite;
}

.button-algo i::after {
  content: "";
  position: absolute;
  width: 10px;
  height: 2px;
  left: 20%;
  bottom: -2px;
  border: 2px solid var(--clr);
  background: #272822;
  transition: 0.2s;
}

.button-algo:hover i::after {
  width: 15px;
  left: 80%;
  animation: move 3s infinite;
}

@keyframes move {
  0% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(5px);
  }
  100% {
    transform: translateX(0);
  }
}

@keyframes box {
  0% {
    box-shadow: #27272c;
  }
  50% {
    box-shadow: 0 0 25px var(--clr);
  }
  100% {
    box-shadow: #27272c;
  }
}
